<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style>
        
    </style>
</head>
<body>
    
</body>
<script>
    // 复杂数组的解析

    // 逐层解析

    var arr = [{
        name:"商品",
        imgs:[{
            title:"图1",
            items:[{
                title:"大图1",
                src:"1-1.jpg"
            },{
                title:"小图1",
                src:"1-2.jpg"
            }]
        },{
            title:"图2",
            items:[{
                title:"大图2",
                src:"2-1.jpg"
            },{
                title:"小图2",
                src:"2-2.jpg"
            }]
        }]
    }]
    console.log(arr);
    console.log(arr[0]);
    console.log(arr[0].imgs);
    console.log(arr[0].imgs[0]);
    console.log(arr[0].imgs[0].items);
    console.log(arr[0].imgs[0].items[1]);
    console.log(arr[0].imgs[0].items[1].src);


</script>
</html>